home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-11-30 | 1.8 KB | 91 lines | [TEXT/KAHL] |
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞
-
- CCTBSwitchboard.c
-
- CommToolbox compatible switchboard.
-
- SUPERCLASS = CSwitchboard.
-
- Copyright © 1992-93 Romain Vignes. All rights reserved.
- modified Ithran Einhorn 1994
-
- ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- #include <CApplication.h> /* TCL includes */
- #include <CDesktop.h>
- #include <Constants.h>
- #include <Global.h>
-
- #include "CCTBApp.h" /* Other includes */
- #include "CCTBSwitchboard.h"
- #include "CFileTransfer.h"
- #include "CTermPane.h"
-
-
- /* Application globals */
-
- extern CApplication *gApplication;
- extern CDesktop *gDesktop;
-
-
- /*
- * ICTBSwitchboard
- *
- * Switchboard object initialisation
- *
- */
-
- void CCTBSwitchboard::ICTBSwitchboard(void)
- {
- CSwitchboard::ISwitchboard(); /* Initialize superclass */
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */
-
- /*
- * DispatchEvent
- *
- * Events dispatching
- *
- * macEvent: Pointer on the event record
- *
- */
-
- void CCTBSwitchboard::DispatchEvent(EventRecord *macEvent)
- {
- WindowPtr theWindow;
- Boolean toolEvent;
-
- toolEvent = FALSE;
- theWindow = NULL;
-
- switch (macEvent->what) {
-
- case mouseDown:
- FindWindow(macEvent->where,&theWindow);
- break;
-
- case activateEvt:
- case updateEvt:
- theWindow = (WindowPtr) macEvent->message;
- break;
- }
-
- if (theWindow != NULL) {
-
- toolEvent = CFileTransfer::cTestToolEvent(macEvent,theWindow);
-
- if (!toolEvent)
- toolEvent = CConnection::cTestToolEvent(macEvent,theWindow);
-
- if (!toolEvent)
- toolEvent = CTermPane::cTestToolEvent(macEvent,theWindow);
- }
-
- if (!toolEvent)
- inherited::DispatchEvent(macEvent); /* Send the evt to its superclass */
- }
-
-
- /* ∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞∞ */